package com.codegzy.service;

import com.codegzy.dao.AdminDAO;
import com.codegzy.entity.Admin;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service("adminService")
@Transactional
public class AdminServiceImpl implements AdminService{

    @Autowired
    private AdminDAO adminDAO;

    @Override
    public void register(Admin admin) {
        adminDAO.register(admin);
    }

    @Override
    public String login(Admin admin) {
        return adminDAO.login(admin);
    }
}
